Appu Goundan
12/18/2025, 7:09 PM@ServiceReference(value = "infoService")
@Optional
abstract Property<InfoService> getInfoService();
@Input
@Optional
public Map<String, Info> getInfo() {
if (!getInfoService().isPresent()) {
return null;
}
return getInfoService().get().getInfo();
}
Are service references not supposed to be inputs? Or is the @ServiceReference annotation just not ideal for this?Appu Goundan
12/18/2025, 7:16 PMAppu Goundan
12/18/2025, 7:17 PMVampire
12/18/2025, 7:29 PMgetInfo a MapProperty and then set it to getInfoService().map(InfoSerivce::getInfo)Appu Goundan
12/18/2025, 7:35 PMVampire
12/18/2025, 7:36 PMAppu Goundan
12/18/2025, 7:38 PMProvider<Map...> not a MapProperty and I always have trouble moving between those twoAppu Goundan
12/18/2025, 7:50 PMVampire
12/18/2025, 7:54 PMAppu Goundan
12/18/2025, 7:58 PMgetInfoService.map(InfoService::getInfo) returns a Provider<Map<String, Info>> .
But is that because my InfoService is misconfigured (returning Map, instead of MapProvider)? or something?Appu Goundan
12/18/2025, 8:16 PMAppu Goundan
12/18/2025, 9:02 PMAppu Goundan
12/18/2025, 9:02 PMVampire
12/19/2025, 8:46 AMVampire
12/19/2025, 8:47 AMMapProperty can be set from a Provider<Map>.Appu Goundan
12/19/2025, 3:58 PMInfoService based on user provided values
Plugin B -> task B: consume InfoService if available (and treat as input).Appu Goundan
12/19/2025, 4:31 PMUnknownDomainObjectException on a call to project.gradle.sharedServices.registrations.namedVampire
12/19/2025, 5:43 PMAppu Goundan
12/19/2025, 5:56 PMUnknownDomainObjectException is thrownVampire
12/20/2025, 12:39 AMAppu Goundan
12/20/2025, 12:46 AM